
package com.zsrt.day0523.jdbc;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.Statement;

public class h2JDBC {


	public static void main(String[] args)throws Exception {
		Class.forName("org.h2.Driver");
		
		String url ="jdbc:h2:~/test";
		String user="jia";
		String password="123";
		Connection connection = DriverManager.getConnection(url, user, password);
		
		Statement cs = connection.createStatement();
		
		String sql = "insert into user_t values(2,'qx',11)";
		int result = cs.executeUpdate(sql );
		System.out.println(result);
	}
}
